#ifndef __ENCODE_H_
#define __ENCODE_H_

enum encoder_msg{
    ENUM_MSG_ENCODER_NONE=0,
    ENUM_MSG_ENCODER_START=1,
    ENUM_MSG_ENCODER_STOP=2,
    ENUM_MSG_ENCODER_RESET=3,
};
    
enum{
	VS_STA_INIT,
	VS_STA_DRVIER_ERR,
	VS_STA_HADWARE_ERR,
	VS_STA_OK,
	VS_STA_ENCODING,
	MAX_ENUM,
};  
    


extern void creat_task_encoder(void);
extern void encoder_msg_start(void);
extern void encoder_msg_stop(void);
extern void encoder_msg_reset(void);

extern int encoder_pull_data(unsigned char *p_dta, unsigned int len);
extern void encoder_clear_cache(void);

extern unsigned char encoder_probe(unsigned int len);
extern const char* encoder_visit_staStr(void);
extern unsigned char encoder_fifodep(void);

/*
demo
    creat_task_encoder();
    encoder_msg_start();
    while(1) 
    {
        if(encoder_probe()) {
            int len = encoder_pull_data(buff, BUFF_SIZE);
            printf("encoder %d bytes\n", len);
        }
        usleep(10*1000);
    }
*/



#endif

